package com.bzkj.basicinfo.mapper;

import com.bzkj.basicinfo.domain.basic.BasicStoArea;
import com.bzkj.basicinfo.domain.ncc.BasicSkuTypeDetail;
import com.bzkj.basicinfo.domain.yxl.vo.YxlBillsListVo;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;

/**
 * @author swj
 * @description 针对表【huoweizl(WMS库区信息表)】的数据库操作Mapper
 */
public interface BasicStoAreaMapper {
    /**
     * 查询货区信息
     *
     * @Author wangzhichao
     * @Date 2024/12/13 11:56:46
     * @Param entity
     */
    List<BasicStoArea> findStoArea(BasicStoArea entity);

    /**
     * 查询所有erp库区信息
     *
     * @param entity
     * @return
     */
    List<BasicStoArea> findErpStock(BasicStoArea entity);

    List<BasicStoArea> selectErpMapStockList(BasicStoArea entity);

    int selectMaxWmsErpId();

    BasicStoArea selectWmsErpMap(@Param("stoId")String stoId,@Param("areaId")String areaId,@Param("erpCode")String erpCode,
                                 @Param("erpName")String erpName,@Param("stoAreaId")String stoAreaId);

    int selectMaxJiXingId();

    int insertWmsErpMap(Map<String, Object> params);

    int insertJiXingMap(Map<String, Object> params);

    List<BasicStoArea> findStoAreaList(BasicStoArea entity);

    /**
     * 插入库区信息
     *
     * @param area
     */
    int insertWarehouse(BasicStoArea area);

    /**
     * 根据仓库id查询库区数据
     *
     * @Author wangzhichao
     * @Date 2024/12/17 08:40:57
     * @Param stoId
     */
    BasicStoArea selectBasicStoAreaById(String stoAreaId);

    /**
     * 修改库区
     *
     * @param area
     * @return
     */
    int updateWarehouse(BasicStoArea area);

    /**
     * 修改库区状态
     *
     * @param ckzht
     * @param hw
     * @return
     */
    int updateBeactiveStatus(@Param("ckzht") String ckzht, @Param("hw") String hw);
    int updateStatus(@Param("status") String status, @Param("id") String id);

    /**
     * 删除库区
     *
     * @param stoId
     * @return
     */
    int deleteWarehouse(String stoId);

    BasicStoArea selectMaxHw();

    List<BasicStoArea> selectJiXingMap(@Param("areaId")String areaId);

    int deleteWmsErpMap(@Param("id")String id);

    int deleteJiXingMap(@Param("areaId")String areaId);

    List<BasicStoArea> findStoAreaTree(BasicSkuTypeDetail entity);


}




